package cn.fsd.nacos;

import cn.fsd.domain.Commodity;
import cn.fsd.vo.ResultBean;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

import static cn.fsd.util.FeignConstant.DeliveryServiceUrl;

@Component
@FeignClient(value = "delivery-server",url = DeliveryServiceUrl)
public interface DeliveryServer {

    @PostMapping("/commodity/getPatch")
    @ApiOperation(value="根据id批量获取商品")
    List<Commodity> getCommodityPatch(@RequestBody List<String> ids);
}